'use strict';

/**
 * @param {Egg.Application} app - egg application
 */
module.exports = app => {
  const { router, controller } = app;
  //登录
  router.post("/api/login", controller.login.login)
  //注册
  router.post("/api/register", controller.login.register)
  //买新房数据
  router.get('/api/hotRoom', controller.home.hotRoom);
  //详情数据
  router.post('/api/Detail', controller.home.Detail);
  //户型 朝向 筛选
  router.post('/api/screening', controller.home.screening);
  //求租 求购 户型 朝向 筛选
  router.post('/api/screening2', controller.home.screening2);

  //楼市圈
  router.get('/api/housingRing', controller.home.housingRing);
  //楼市圈删除
  router.post('/api/housingRingDel', controller.home.housingRingDel);


  //经纪人 消息 排序 列表
  router.get('/api/newsList', controller.home.newsList);
  //经纪人 消息列表删除
  router.post('/api/newsDel', controller.home.newsDel);
  //经纪人 排行排序搜索
  router.post('/api/rankingsearch', controller.home.rankingsearch);

  //直播
  router.get('/api/liveList', controller.home.liveList);
  //团购
  router.get('/api/tableData2', controller.home.tableData2);

};
